package ThreadTest;

class ProMyThread implements Runnable{
    @Override
    public void run() {

        for (int i=0;i<10;i++){
            System.out.println(Thread.currentThread().getName()+"运行，i="+i);
        }

    }
}

public class ProDemo {

    public static void main(String[] args) {
        ProMyThread pro= new ProMyThread();
        Thread t1=new Thread(pro);
        Thread t2=new Thread(pro);
        Thread t3=new Thread(pro);
        t1.setPriority(Thread.MIN_PRIORITY);
        t1.start();
        t2.setPriority(Thread.MAX_PRIORITY);
        t2.start();
        t3.setPriority(Thread.NORM_PRIORITY);
        t3.start();
    }




}
